package com.ktjy.web.service.impl;


import com.ktjy.web.dao.RoleDao;
import com.ktjy.web.dao.impl.RoleDaoImpl;
import com.ktjy.web.entity.Role;
import com.ktjy.web.service.RoleService;

import java.util.List;

public class RoleServiceImpl implements RoleService {
    RoleDao dao=new RoleDaoImpl();

    @Override
    public List<Role> selRoleAll() {
        return dao.selRoleAll();
    }

    @Override
    public List<Role> selRoleByNameAll(String roleName) {
        return dao.selRoleByNameAll(roleName);
    }

    @Override
    public Role selRoleById(int id) {
        return dao.selRoleById(id);
    }

    @Override
    public Role selRoleByName(String roleName) {
        return dao.selRoleByName(roleName);
    }

    @Override
    public int addRole(Role role) {
        return dao.addRole(role);
    }

    @Override
    public int updateRole(Role role) {
        return dao.updateRole(role);
    }

    @Override
    public int delRole(int id) {
        return dao.delRole(id);
    }
}
